package com.introduce;

/**
 * 引入Null对象
 *
 * @author: cong zhi
 * @createDate: 2022/5/10 8:37
 * @updateUser: cong zhi
 * @updateDate: 2022/5/10 8:37
 * @updateRemark: 修改内容
 * @version: v1.0
 */
public class BillingPlan {


    private int basicpay;

    private int extrapay;


    public BillingPlan() {
        setBasicpay(0);
        setExtrapay(0);
    }

    public BillingPlan(int pay) {
        setBasicpay(pay);
        setExtrapay(0);
    }

    public BillingPlan(int basicpay, int extrapay) {
        this.basicpay = basicpay;
        this.extrapay = extrapay;
    }

    public static BillingPlan basic() {
        // 最低消费100元
        return new BillingPlan(100);
    }

    public int getTotalExpand() {
        return basicpay + extrapay;
    }

    public int getBasicpay() {
        return basicpay;
    }

    public void setBasicpay(int basicpay) {
        this.basicpay = basicpay;
    }

    public int getExtrapay() {
        return extrapay;
    }

    public void setExtrapay(int extrapay) {
        this.extrapay = extrapay;
    }
}
